package com.dykj.fireFighting.server.socialUnit.firemanger.mapper;

import com.dykj.fireFighting.api.socialUnit.firemanger.entity.KeyPartsDevice;
import com.dykj.fireFighting.common.core.mapper.SuperMapper;

import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

import java.util.List;
import java.util.Map;

/**
 * @Description 重点部位设备中间表
 * @Author aixiaolan
 * @Date  2021-07-06 08:42:32
 */
public interface KeyPartsDeviceMapper extends SuperMapper<KeyPartsDevice> {

    @Select("select device_id from key_parts_device where key_parts_id=#{keyPartsId} and type=#{type}" )
    List<String> getByKeyPartsId(@Param("keyPartsId") String keyPartsId,@Param("type") Integer type);

    @Delete("DELETE FROM key_parts_device where key_parts_id=#{keyPartsId}")
    int delByKeyPartsId(@Param("keyPartsId") String keyPartsId);

	
}